<?php
namespace app\api\controller;
use Endroid\QrCode\QrCode;
class Com
{
    //二维码
    public function qrcode(){
        $txt = urldecode(input('txt'));
        $qrCode = new QrCode($txt);
        header('Content-Type: '.$qrCode->getContentType());
        echo $qrCode->writeString();
        exit;
    }
}
